package org.xy;

import java.util.Timer;
import java.util.TimerTask;

public class VirtualThread {

    public static void main(String[] args) throws InterruptedException {
        Thread.ofVirtual().start(()->{
           System.out.println("VirtualThread");

        }).join();
        System.out.println("End");
        var t = new Timer();
        t.schedule(new TimerTask() {
            @Override
            public void run() {
                System.out.println("timer");
            }
        }, 1000,100);

    }
}
